<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Insert title here</title>
<link rel="stylesheet" href="${path}/statics/layui/css/layui.css">

</head>
<body>
	
     <form class="layui-form" action="" style = "padding : 10px;">
     
     <input type="hidden" name="id" value="${sys.id}">
     
	  <div class="layui-form-item">
	    <label class="layui-form-label">公司名</label>
	    <div class="layui-input-block">
	      <input type="text" name="comName" id="comId" value="${sys.com_name}" autocomplete="off" placeholder="请输入标题" class="layui-input">
	    </div>
	  </div>
	   <div class="layui-form-item">
	    <label class="layui-form-label">网站名</label>
	    <div class="layui-input-block">
	      <input type="text" name="webName" id="webId" value="${sys.web_name}" autocomplete="off" placeholder="请输入标题" class="layui-input">
	    </div>
	  </div>
	  <div class="layui-form-item">
	    <label class="layui-form-label">联系人</label>
	    <div class="layui-input-block">
	      <input type="text" name="reper" id="reperId" value="${sys.reper}" autocomplete="off" placeholder="请输入标题" class="layui-input">
	    </div>
	  </div>
	  <div class="layui-form-item">
	    <label class="layui-form-label">联系电话</label>
	    <div class="layui-input-block">
	      <input type="text" name="reMobile" id="mobileId" value="${sys.re_mobile}" autocomplete="off" placeholder="请输入标题" class="layui-input">
	    </div>
	  </div>
	  <div class="layui-form-item">
	    <label class="layui-form-label">地址</label>
	    <div class="layui-input-block">
	      <input type="text" name="address" id="addressId" value="${sys.address}" autocomplete="off" placeholder="请输入标题" class="layui-input">
	    </div>
	  </div>
 		<div class="layui-form-item">
	    <label class="layui-form-label">备案号</label>
	    <div class="layui-input-block">
	      <input type="text" name="record" id="recordId" value="${sys.record}" autocomplete="off" placeholder="请输入标题" class="layui-input">
	    </div>
	  </div>

  
  <div class="layui-form-item">
    <div class="layui-input-block">
      <button type="submit" class="layui-btn" name="submit" id="saveBtnID" lay-submit lay-filter="saveBtn">保存</button>
      <button type="reset" class="layui-btn layui-btn-primary">重置</button>
    </div>
  </div>
</form>
  
	
<script src="${path}/statics/layui/layui.js"></script>
<script>
//JavaScript代码区
layui.use(['form','laydate','jquery','layer',"table"], function(){
  var form = layui.form;
  var $ = layui.jquery;
  var layer = layui.layer;
  var table = layui.table;

	  //监听表单的提交,首先会触发表单的验证,
	form.on('submit(saveBtn)', function(data){
		
	  $.post("${path}/sysCtl/list",$(data.form).serialize(),function(res){
		  
		  if(res == 0){
			  layer.msg("保存成功",{icon:1},function(){
				  location.reload();
			  });
			  
		  }else{
			  layer.msg("系统繁忙,请稍后",{icon:2});
		  }
		
	  })
	  return false;//阻止layui同步表单提交
	});
 
}); 
</script>



</body>
</html>